import React from 'react';
import { connect } from 'react-redux';
import { View, Image } from '@tarojs/components';
import './index.scss';

const Preview = ({ seletEinvoiceDetail = {} }) => {
  return (
    <View className="preview">
      <View className="header">
        {seletEinvoiceDetail.urlList?.length > 0 &&
          seletEinvoiceDetail.urlList.map((url) => {
            return <Image src={url} className="invoice" />;
          })}
      </View>
    </View>
  );
};
export default connect(({ invoiceAssistant }) => ({
  seletEinvoiceDetail: invoiceAssistant.seletEinvoiceDetail,
}))(Preview);
